import 'package:flutter/material.dart';

class Router {
  static const String detail = 'detail';
  static const String defalt_home = 'defalt_home';
  static const String js_home = 'js_home';
  static const String erp_home = 'erp_home';
  static const String obtainid = '/obtainid';

  static Route<dynamic> generateRoute(RouteSettings settings) {
    switch (settings.name) {
      //根据名称跳转相应页面
      case js_home:
      default:
        return MaterialPageRoute(
            builder: (_) => Scaffold(
                  body: Center(
                    child: Text('No route defined for ${settings.name}'),
                  ),
                ));
    }
  }


}
